home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
VRML 2.0 Sourcebook (2nd Edition)
/
VRML 2.0 Sourcebook CD [md5 fed90f4f9c39d5a60d477058775c7e21].iso
/
book
/
win
/
ch30
/
30fig01.wrl
< prev
next >
Wrap
Text File
|
1996-09-23
|
1KB
|
49 lines
#VRML V2.0 utf8
# The VRML 2.0 Sourcebook
# Copyright [1997] By
# Andrea L. Ames, David R. Nadeau, and John L. Moreland
Group {
children [
Background {
skyColor [ 1.0 0.0 0.8, 0.5 0.0 0.8, 0.0 0.0 0.8 ]
skyAngle [ 1.309, 1.571 ]
groundColor [ 0.0 0.0 0.1, 0.0 0.1 0.3, 0.3 0.3 0.6 ]
groundAngle [ 1.309, 1.571 ]
},
# Floor
Shape {
appearance Appearance {
material Material { }
}
geometry Box { size 2.0 0.01 0.5 }
},
# Animating red ball
Transform {
translation 0.0 1.1 0.0
children DEF BallTransform Transform {
children Shape {
appearance Appearance {
material Material {
diffuseColor 1.0 0.3 0.3
}
}
geometry Sphere { radius 0.1 }
}
}
},
# Animation clock
DEF Clock TimeSensor {
cycleInterval 4.0
loop TRUE
},
# Script
DEF Mover Script {
url "move1.js"
eventIn SFFloat set_fraction
eventOut SFVec3f value_changed
}
]
}
ROUTE Clock.fraction_changed TO Mover.set_fraction
ROUTE Mover.value_changed TO BallTransform.set_translation